{include 'admin/layout/header_list'}
<link rel="stylesheet" href="__ADMIN_STATIC__/css/addContent.css?random={extendSetting('random')}">
<div class="addcontent">
    <form class="ajaxForm" method="post">
        <input type="hidden" name="_method" value="put">
        <input type="hidden" name="id" value="{if isset($info['id'])}{$info['id']}{/if}" >
        <table class="table">
            <tr>
                <td class="tl">
                    <span><strong>* </strong>菜单id</span>
                </td>
                <td>
                    <select name="menuId">
                        <option value="0">无菜单id</option>
                        {if $adminMenuVal}
                        {foreach $adminMenuVal $key $val}
                        <option value="{$key}"  {if $key==$info['menuId']}selected{/if}>{$val}</option>
                        {/foreach}
                        {/if}
                    </select>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong>* </strong>路由请求方法</span>
                </td>
                <td>
                    <select name="routhAction">
                        <option value="1" {if !$info} selected {/if} {if $info} {$info['routhAction']==1 ?"selected":""} {/if} >get</option>
                        <option value="2" {if $info} {$info['routhAction']==2 ?"selected":""} {/if} >post</option>
                        <option value="3" {if $info} {$info['routhAction']==3 ?"selected":""} {/if}>put</option>
                        <option value="4" {if $info} {$info['routhAction']==4 ?"selected":""} {/if}>delete</option>
                    </select>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>路由地址</span>
                </td>
                <td>
                    <input class="long" type="text" name="route" value="{if isset($info['route'])}{$info['route']}{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>命名空间控制器名称</span>
                </td>
                <td>
                    <input class="long" type="text" name="moduleName" value="{if isset($info['moduleName'])}{$info['moduleName']}{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>命名空间控制器</span>
                </td>
                <td>
                    <input class="long" type="text" name="module" value="{if isset($info['module'])}{$info['module']}{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>控制器方法名称</span>
                </td>
                <td>
                    <input class="long" type="text" name="actionName" value="{if isset($info['actionName'])}{$info['actionName']}{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>控制器方法</span>
                </td>
                <td>
                    <input class="long" type="text" name="action" value="{if isset($info['action'])}{$info['action']}{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>其他参数</span>
                </td>
                <td>
                    <input class="long" type="text" name="other" value="{if isset($info['other'])}{$info['other']}{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong></strong>是否显示</span>
                </td>
                <td>
                    <select name="isShow">
                        <option value="1" {if $info} {$info['isShow']==1 ?"selected":""} {/if}>显示</option>
                        <option value="2" {if $info} {$info['isShow']==2 ?"selected":""} {/if}>隐藏</option>
                    </select>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong>* </strong>是否启用</span>
                </td>
                <td>
                    <select name="isEnable">
                        <option value="1" {if $info} {$info['isEnable']==1 ?"selected":""} {/if}>启用</option>
                        <option value="2" {if $info} {$info['isEnable']==2 ?"selected":""} {/if}>停用</option>
                    </select>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>排序</span>
                </td>
                <td>
                    <input class="" type="number" name="sort" value="{if isset($info['action'])}{$info['sort']}{else}1{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>描述</span>
                </td>
                <td>
                    <input class="long" type="text" name="description" value="{if isset($info['description'])}{$info['description']}{/if}">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span><strong> </strong>来源插件id</span>
                </td>
                <td>
                    <input class="long" type="text" name="plugins" value="{if isset($info['plugins'])}{$info['plugins']}{/if}">
                </td>
            </tr>
        </table>
    </form>
    <div class="ltcms-button">
        <button class="btns submit ajaxBtn" type="button" data-submit-url="{LTCMS_ROUTE_PREFIX}/adminFunc/edit" data-form=".ajaxForm" data-location-url="{LTCMS_ROUTE_PREFIX}/adminFunc/index" data-close="5">
            确认保存
        </button>
        <button class="btns cancel">取消并返回</button>
    </div>
</div>
<script src="__ADMIN_STATIC__/js/addContent.js?random={extendSetting('random')}"></script>
{include 'admin/layout/footer'}